<?php $this->beginContent('/layouts/main'); ?>

<DIV class="ui-layout-west">
	<div id="sidebar">
		<?php
			$this->beginWidget('zii.widgets.CPortlet', array(
				'title'=>'Operations',
			));
			$this->widget('zii.widgets.CMenu', array(
				'items'=>$this->menu,
				'htmlOptions'=>array('class'=>'operations'),
			));
			
			$this->endWidget();
			
						
			if ('post' === Yii::app()->getController()->getId()) {
				$this->widget('CategoryList');
				//$this->widget('TagCloud', array('maxTags' => 20));
			}
			
			//category
//			$this->beginWidget('zii.widgets.CPortlet', array('title' => 'Category'));
//			$this->widget('zii.widgets.CMenu', array(
//			    'items' => $this->categorys
//			));
//			$this->endWidget();
		?>
	</div>
</DIV>

<DIV class="ui-layout-center">
    <?php echo $content; ?>
</DIV>

<script type="text/javascript">
    $(function(){
        $("#main").height($(window).height() - 70);
    });
</script>

<?php $this->endContent(); ?>